		<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Faulty</title>

<style type="text/css">
/* <![CDATA[ */

table, td
{
    border-color: #666;
    border-style: solid;
}
table, th
{
    border-color: #666;
    border-style: solid;
}

table
{
    border-width: 0 0 1px 1px;
    border-spacing: 0;
    border-collapse: collapse;
}
 
td
{
    margin: 0;
    padding: 4px;
    border-width: 1px 1px 0 0;
}
th
{
    margin: 0;
    padding: 4px;
    border-width: 1px 1px 0 0;
}

/* ]]> */
</style>

<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>

<script language="javascript">
function enableUpload(){

	var staffDis = $('#staff_name_dis').val();
	var comm = $('#faulty_comment').val();
	
	var tech = $('#name_tech').val();
	var idJob = $('#id_job').val();

	var basicCheck = false;

	if(staffDis.length > 0 && comm.length > 5 && tech.length > 1){
		basicCheck = true;
	}

	if(basicCheck){
		
		$('#sub_upload').removeAttr('disabled');
		$("#hint").html('');
			
	}
	else{
		
		$('#sub_upload').attr('disabled','disabled');
		$("#hint").html('Still Missing Some Information');
		if(idJob.length != 13 && idJob.length != 10 ){
			$("#hint").html('Check Job ID');	
		}

	}	

}

</script>

</head>

<body style="font-family:Arial, Helvetica, sans-serif;"> 
<form id="form1" name="form1" method="post" > 
	<?php if($this->check == true){?>
			<h2>Warranty for Job <?php echo $this->idJob?><br/></h2>
			<h3><?php echo $this->message?></h3>
			
			Input Part Code:<input type = "text" name = "part" ></input><br/><br/>
			<input type = "hidden" name = "password" value = "pass"></input>
			<input type = "submit" name = "submit" value = "Submit"></input>
			
	<?php }else{?>
			
			<h2>Warranty for Job <?php echo $this->idJob?><br/></h2>
			<h3 style = "color:red"><?php echo $this->message?></h3>
			
			Input Part Code:<input type = "text" name = "part" ></input><br/><br/>
			<input type = "hidden" name = "password" value = "notpass"></input>
			<input type = "submit" name = "submit" value = "Submit"></input>
	
	<?php }?>
</form>
<br/><br/>

<a href="/repaircenter/re-open-job-warranty/jobid/<?php echo $this->idJob;?>/shophead/<?php echo $this->shophead?>" target="_blank" >Re-open for adjust part</a>


</body>
</html>